package com.assignwork.entity.pc;


import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.NullSerializer;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.tenant.mp.TenantEntity;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "排船计划", description = "")
@TableName("pc_ship_plan")
public class PcShipPlan extends TenantEntity implements Serializable {
    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(name = "主键")
    private Long id;
    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(name = "船舶ID")
    private Long shipId;
    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(name = "泊位ID")
    private Long berthId;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    @ApiModelProperty(value = "靠泊时间")
    private LocalDateTime inBerthTime;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    @ApiModelProperty(value = "离泊时间")
    private LocalDateTime outBerthTime;
    @ApiModelProperty(name = "是否移动泊", notes = "是否有排船计划")
    private Integer isMoveBerth;
    @JsonSerialize(using = ToStringSerializer.class,nullsUsing = NullSerializer.class)
    @ApiModelProperty(name = "移泊载货量（吨）", notes = "")
    private BigDecimal moveBerthCargoDeadWeight;
    @ApiModelProperty(name = "船时效率", notes = "")
    private BigDecimal shipEfficiency;
}
